package com.guqj.pattern.proxy;

public class ProxyTest {

	public static void main(String[] args) throws Exception {
		ProxyVisitor visitor = new ProxyVisitor();
		try {
			visitor.visit();
			visitor.publish();
			visitor.comment();
			visitor.remove();
		} catch (Exception e) {
			e.printStackTrace();
		} finally {
			System.out.println("finally");
		}
		visitor = new ProxyVisitor(new Manager());
		visitor.visit();
		visitor.publish();
		visitor.comment();
		visitor.remove();
	}
}
